package com.hzdesk.media.koreabatchmatvector.custom;

import android.content.Context;
import android.util.AttributeSet;
import android.widget.VideoView;

/**
 * 
 * @author Mr.Lee
 *
 */
public class DeskmediaVideoView extends VideoView {

	private PlayPauseListener mListener;

	public DeskmediaVideoView(Context paramContext) {
		super(paramContext);
	}

	public DeskmediaVideoView(Context paramContext, AttributeSet paramAttributeSet) {
		super(paramContext, paramAttributeSet);
	}

	public DeskmediaVideoView(Context paramContext, AttributeSet paramAttributeSet, int paramInt) {
		super(paramContext, paramAttributeSet, paramInt);
	}

	public void SetPlayPauserListener(PlayPauseListener paramPlayPauseListener) {
		this.mListener = paramPlayPauseListener;
	}

	public void pause() {
		super.pause();
		if (this.mListener == null)
			return;
		this.mListener.onPause();
	}

	public void start() {
		super.start();
		if (this.mListener == null)
			return;
		this.mListener.onPlay();
	}

	public static abstract interface PlayPauseListener {
		public abstract void onPause();
		public abstract void onPlay();
	}

}
